<?php
//设置utf-8编码
header('Content-Type:text/html;charset=utf-8');

// 开启session功能
session_start();

// php在服务器上 $_SERVER['HTTP_REFERER'] 出现Undefined index: HTTP_REFERER 解决方法
error_reporting(E_ERROR | E_WARNING | E_PARSE);

//网站根目录
define('ROOT_PATH',dirname(__FILE__));
//设置中国时区
date_default_timezone_set('Asia/Shanghai');

//引入配置信息
require ROOT_PATH.'/configs/profile.inc.php';
// 自动加载类
require ROOT_PATH.'/includes/WeixinApi.class.php';
require ROOT_PATH.'/includes/JSSDK.class.php';
require ROOT_PATH.'/includes/Tool.class.php';
require ROOT_PATH.'/includes/DB.class.php';
require ROOT_PATH.'/model/Model.class.php';
require ROOT_PATH.'/model/UserModel.class.php';

$wechatObj = new WeixinApi();
$wechatObj->init(APPID,APPSECRET);
?>